home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Interactive Web Graphics with Shout 3D
/
Interactive Web Graphics With Shout 3D.iso
/
pc
/
Shout3Ddemo
/
Shout3d_runtime
/
codebase
/
models
/
BooleanEventToIntegerTest.s3d
< prev
next >
Wrap
Text File
|
2000-05-30
|
4KB
|
179 lines
#VRML V2.0 utf8
WorldInfo {
title "Spazz3D"
info [
"This VRML World was created with Spazz3D, a VRML 97 authoring tool"
"www.spazz3d.com"
]
}
DEF DUMMY Transform{
children[
DEF dad_Box1 Transform {
translation -1.87176 0.86 0.0
rotation 0.865 0.503 0.0 0.684
children [
DEF BOX1_TOUCHSENSOR TouchSensor{}
DEF Box1 Shape {
appearance Appearance {
material DEF Red_mat Material {
diffuseColor 1.0 0.0 0.0
}
}
geometry IndexedFaceSet {
solid TRUE
creaseAngle 1.047
coord Coordinate {
point [
-0.50000 0.50000 -0.50000
-0.50000 0.50000 0.50000
0.50000 0.50000 0.50000
0.50000 0.50000 -0.50000
-0.50000 -0.50000 -0.50000
-0.50000 -0.50000 0.50000
0.50000 -0.50000 0.50000
0.50000 -0.50000 -0.50000
]
}
coordIndex [
0 1 2 -1
0 2 3 -1
1 5 6 -1
1 6 2 -1
2 6 7 -1
2 7 3 -1
3 7 4 -1
3 4 0 -1
0 4 5 -1
0 5 1 -1
6 5 4 -1
6 4 7 -1
]
}
}
]
}
]
}
DEF SWITCH Switch{
whichChoice -1
choice[
DEF CHOICE_0 Transform {
translation 0 0.86 0.0
rotation 0.865 0.503 0.0 0.684
children [
DEF Box1 Shape {
appearance Appearance {
material DEF Red_mat Material {
diffuseColor 1.0 0.0 0.0
}
}
geometry IndexedFaceSet {
solid TRUE
creaseAngle 1.047
coord Coordinate {
point [
-0.50000 0.50000 -0.50000
-0.50000 0.50000 0.50000
0.50000 0.50000 0.50000
0.50000 0.50000 -0.50000
-0.50000 -0.50000 -0.50000
-0.50000 -0.50000 0.50000
0.50000 -0.50000 0.50000
0.50000 -0.50000 -0.50000
]
}
coordIndex [
0 1 2 -1
0 2 3 -1
1 5 6 -1
1 6 2 -1
2 6 7 -1
2 7 3 -1
3 7 4 -1
3 4 0 -1
0 4 5 -1
0 5 1 -1
6 5 4 -1
6 4 7 -1
]
}
}
]
}
DEF CHOICE_1 Transform {
translation 0 0.86 0.0
rotation 0.865 0.503 0.0 0.684
scale 2 2 2
children [
DEF Box1 Shape {
appearance Appearance {
material DEF Green_mat Material {
diffuseColor 0.0 1.0 0.0
}
}
geometry IndexedFaceSet {
solid TRUE
creaseAngle 1.047
coord Coordinate {
point [
-0.50000 0.50000 -0.50000
-0.50000 0.50000 0.50000
0.50000 0.50000 0.50000
0.50000 0.50000 -0.50000
-0.50000 -0.50000 -0.50000
-0.50000 -0.50000 0.50000
0.50000 -0.50000 0.50000
0.50000 -0.50000 -0.50000
]
}
coordIndex [
0 1 2 -1
0 2 3 -1
1 5 6 -1
1 6 2 -1
2 6 7 -1
2 7 3 -1
3 7 4 -1
3 4 0 -1
0 4 5 -1
0 5 1 -1
6 5 4 -1
6 4 7 -1
]
}
}
]
}
]
}
DEF Light1 DirectionalLight {
ambientIntensity 0.000
intensity 1.000
direction 0.99489 0.08952 0.04676
color 1.0 1.0 1.0
on FALSE
}
DEF TOGGLE Toggle{}
DEF BOOLEAN_TO_INTEGER_0 BooleanEventToInteger{
intField 0
}
DEF BOOLEAN_TO_INTEGER_1 BooleanEventToInteger{
intField 1
}
ROUTE BOX1_TOUCHSENSOR.touchTime TO TOGGLE.toggleTime
ROUTE TOGGLE.toggleValue TO BOOLEAN_TO_INTEGER_0.trueFilter
ROUTE BOOLEAN_TO_INTEGER_0.intField TO SWITCH.whichChoice
ROUTE TOGGLE.toggleValue TO BOOLEAN_TO_INTEGER_1.falseFilter
ROUTE BOOLEAN_TO_INTEGER_1.intField TO SWITCH.whichChoice